home *** CD-ROM | disk | FTP | other *** search
/ Webster's Millennium Amer…Sign Language Dictionary / ASL.ISO / mac / SKILLS.dir / 00061_Script_START GAME rollover script < prev    next >
Text File  |  2001-09-05  |  3KB  |  111 lines

  1. on mouseUp
  2.   global  whichSkills
  3.   if whichSkills = "practice/test" then test
  4.   if whichSkills = "concentration" then conc
  5.   go the frame
  6. end
  7.  
  8. on conc
  9.   global gGameType,NumPlayers,gDataSource
  10.   set notDone = false
  11.   if not notDone and gGameType = "" then 
  12.     alertBox "Choose fs or asl signs."
  13.     set notDone = true
  14.   end if
  15.   if not notDone and gDataSource = "" and gGameType = "qt" then 
  16.     alertBox "Choose data source."
  17.     set notDone = true
  18.   end if
  19.   if not notDone and NumPlayers = 0 then 
  20.     alertBox "Choose number of players."
  21.     set notDone = true
  22.   end if
  23.   
  24.   repeat with i = 3 to 11
  25.     puppetSprite i, false
  26.   end repeat
  27.   set the visible of sprite 36 = true
  28.   repeat with i = 3 to 7
  29.     set the visible of sprite i = true
  30.   end repeat
  31.   if  notDone then
  32.     go frame frame()-1
  33.   else 
  34.     put " " into field "p1 title" 
  35.     put " " into field "p1 score" 
  36.     put " " into field "p2 title" 
  37.     put " " into field "p2 score" 
  38.     go frame "concentration"&&gGameType
  39.     unload
  40.   end if
  41.   --alert "go to game"
  42. end
  43.  
  44. on test
  45.   global gTest,gDataType,gTestType,gNumQs,gDataSource
  46.   repeat with i = 3 to 17
  47.     puppetSprite i, false
  48.   end repeat
  49.   set the visible of sprite 35 = false --turns off hints every new game
  50.   updatestage
  51.   
  52.   
  53.   set notDone = false
  54.   if not notDone and gDataType = "" then
  55.     alertBox "Choose data type."
  56.     set notDone = true
  57.   end if
  58.   if not notDone and gTestType = "" then 
  59.     alertBox "Choose test type."
  60.     set notDone = true
  61.   end if
  62.   if not notDone and gNumQs = 0 then 
  63.     alertBox "Choose # of questions."
  64.     set notDone = true
  65.   end if
  66.   if not notDone and not (gDatatype = "fs") and gDataSource = "" then 
  67.     alertBox "Choose data source."
  68.     set notDone = true
  69.   end if
  70.   
  71.   if  notDone then
  72.     go frame frame()-1
  73.   else
  74.     if (gTestType = "multiple choice") then setUpTest
  75.     else set the visible of sprite 39 = false
  76.     
  77.     put "00:00" into field "numTime"
  78.     put "0 of"&&gNumQs into field "whichq"
  79.     put "Points Scored: 0" into field "testScore"
  80.     
  81.     repeat with i = 43 to 46
  82.       set the visible of sprite i = false
  83.     end repeat
  84.     
  85.     if gTest then
  86.       if (gTestType = "multiple choice") then go frame "testm"
  87.       else 
  88.         put "" into field "fill-in word"
  89.         go frame "test"
  90.       end if
  91.     else 
  92.       if gDatatype = "fs" then set the visible of sprite 36 = true
  93.       else set the visible of sprite 36 = false
  94.       if (gTestType = "multiple choice") then go frame "pract"
  95.       else 
  96.         put "" into field "fill-in word"
  97.         go frame "practf"
  98.       end if
  99.     end if
  100.     
  101.     getQuestions gNumQs,gDataSource,gDataType
  102.     
  103.     --alert "go to practice or test"
  104.     repeat with i = 13 to 17
  105.       set the visible of sprite i = true
  106.     end repeat
  107.     unload
  108.     updateStage
  109.   end if
  110. end
  111.